﻿<Application
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:Custom="http://schemas.microsoft.com/surface/2008" x:Class="SurfaceClient.App"
    StartupUri="MainWindow.xaml"
    >
    <Application.Resources>
      <ResourceDictionary>
        <ResourceDictionary.MergedDictionaries>
          <ResourceDictionary Source="/Microsoft.Surface.Presentation.Generic;v2.0.0.0;31bf3856ad364e35;component/themes\generic.xaml"/>
               

            </ResourceDictionary.MergedDictionaries>
      	<SolidColorBrush x:Key="LCD" Color="#FF5E5E5E"/>
            <SolidColorBrush x:Key="BlueHighlight" Color="#FFE59E00"></SolidColorBrush>
            <BorderGapMaskConverter x:Key="BorderGapMaskConverter"/>
            <Style TargetType="{x:Type GroupBox}">
            	<Setter Property="BorderBrush" Value="#D5DFE5"/>
            	<Setter Property="BorderThickness" Value="1"/>
            	<Setter Property="Template">
            		<Setter.Value>
            			<ControlTemplate TargetType="{x:Type GroupBox}">
            				<Grid SnapsToDevicePixels="true">
            					<Grid.ColumnDefinitions>
            						<ColumnDefinition Width="6"/>
            						<ColumnDefinition Width="Auto"/>
            						<ColumnDefinition Width="*"/>
            						<ColumnDefinition Width="6"/>
            					</Grid.ColumnDefinitions>
            					<Grid.RowDefinitions>
            						<RowDefinition Height="Auto"/>
            						<RowDefinition Height="Auto"/>
            						<RowDefinition Height="*"/>
            						<RowDefinition Height="6"/>
            					</Grid.RowDefinitions>
            					<Border BorderBrush="Transparent" Background="{TemplateBinding Background}" Grid.ColumnSpan="4" Grid.Column="0" CornerRadius="0" Grid.Row="1" Grid.RowSpan="3"/>
            					<Border x:Name="Header" Grid.Column="0" Padding="3,1,3,3" Grid.Row="0" Grid.RowSpan="2" Grid.ColumnSpan="4" Background="{DynamicResource BlueHighlight}">
            						<ContentPresenter ContentSource="Header" RecognizesAccessKey="True" SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"/>
            					</Border>
            					<ContentPresenter Grid.ColumnSpan="2" Grid.Column="1" Grid.Row="2" SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"/>
            				</Grid>
            			</ControlTemplate>
            		</Setter.Value>
            	</Setter>
            </Style>
            <SolidColorBrush x:Key="ControlHitAreaBrush"    
            	Color="#00FFFFFF"/>
            <Style x:Key="SurfaceHitAreaBaseStyle"
            	TargetType="{x:Type Control}">
            	<Setter Property="SnapsToDevicePixels"
            		Value="False"/>
            	<Setter Property="Background"
            		Value="{StaticResource ControlHitAreaBrush}"/>
            	<Setter Property="IsTabStop"
            		Value="False"/>
            	<Setter Property="Focusable"
            		Value="False"/>
            	<Setter Property="FocusVisualStyle"
            		Value="{x:Null}"/>
            	<Setter Property="MinWidth"
            		Value="40" />
            	<Setter Property="MinHeight"
            		Value="40" />
            </Style>
            <Style x:Key="SliderToolTipStyle"
            	TargetType="{x:Type Label}">
            	<Setter Property="Visibility"
            		Value="Collapsed"/>
            	<Setter Property="ClipToBounds"
            		Value="False"/>
            	<Setter Property="Background"
            		Value="{DynamicResource {x:Static Custom:SurfaceColors.ToolTipBackgroundBrushKey}}"/>
            	<Setter Property="Foreground"
            		Value="{DynamicResource {x:Static Custom:SurfaceColors.ToolTipForegroundBrushKey}}"/>
            	<Setter Property="Padding"
            		Value="5,2,5,3"/>
            	<Setter Property="Template">
            		<Setter.Value>
            			<ControlTemplate TargetType="{x:Type Label}">
            				<Grid Background="{DynamicResource {x:Static Custom:SurfaceColors.ButtonBackgroundBrushKey}}" >
            					<Border						  
            						HorizontalAlignment="Stretch"                          
            						Background="{TemplateBinding Background}"                   
            						Opacity="{TemplateBinding Opacity}">
            						<TextBlock
            							Margin="{TemplateBinding Padding}"
            							Foreground="{TemplateBinding Foreground}"                            
            							Text="{TemplateBinding Content}"/>
            					</Border>
            				</Grid>
            			</ControlTemplate>
            		</Setter.Value>
            	</Setter>
            </Style>
            <Style x:Key="SliderHorzDecreaseRepeatButtonStyle"
            	TargetType="{x:Type Custom:SurfaceRepeatButton}" >
            	<Setter Property="Interval"
            		Value="150"/>
            	<Setter Property="OverridesDefaultStyle" 
            		Value="True"/>
            	<Setter Property="IsTabStop" 
            		Value="False"/>
            	<Setter Property="Focusable" 
            		Value="False"/>
            	<Setter Property="Template" >
            		<Setter.Value>
            			<ControlTemplate TargetType="{x:Type Custom:SurfaceRepeatButton}">
            				<Grid Background="{StaticResource ControlHitAreaBrush}" MinHeight="38" MaxHeight="38">
            					<Rectangle VerticalAlignment="Top"
            						Margin="1,14,1,0"	
            						MinHeight="2"	
            						Fill="{DynamicResource {x:Static Custom:SurfaceColors.SliderTrackDecreaseBackgroundBrushKey}}"/>
            				</Grid>
            			</ControlTemplate>
            		</Setter.Value>
            	</Setter>
            </Style>
            <Style x:Key="SliderHorzIncreaseRepeatButtonStyle"
            	TargetType="{x:Type Custom:SurfaceRepeatButton}" >
            	<Setter Property="Interval"
            		Value="150"/>
            	<Setter Property="OverridesDefaultStyle" 
            		Value="True"/>
            	<Setter Property="IsTabStop" 
            		Value="False"/>
            	<Setter Property="Focusable" 
            		Value="False"/>
            	<Setter Property="Template">
            		<Setter.Value>
            			<ControlTemplate TargetType="{x:Type Custom:SurfaceRepeatButton}">
            				<Grid Background="{StaticResource ControlHitAreaBrush}" MinHeight="38" MaxHeight="38">
            					<Rectangle  VerticalAlignment="Top"
            						Margin="1,14,1,0"
            						MinHeight="2"
            						Fill="{DynamicResource {x:Static Custom:SurfaceColors.SliderTrackIncreaseBackgroundBrushKey}}"/>
            				</Grid>
            			</ControlTemplate>
            		</Setter.Value>
            	</Setter>
            </Style>
            <Style x:Key="SurfaceThumbStyle"
            	TargetType="{x:Type Custom:SurfaceThumb}"
            	BasedOn="{StaticResource SurfaceHitAreaBaseStyle}">
            	<Setter Property="Custom:TouchVisualizer.Adapter">
            		<Setter.Value>
            			<Custom:RectangleTouchVisualizerAdapter RadiusX="15"
            				RadiusY="15"/>
            		</Setter.Value>
            	</Setter>
            	<Setter Property="MinHeight" Value="6"/>
            	<Setter Property="MinWidth" Value="6"/>
            	<Setter Property="Template">
            		<Setter.Value>
            			<ControlTemplate TargetType="{x:Type Custom:SurfaceThumb}">
            				<ControlTemplate.Resources>
          <!-- Horizontal orientation -->
            					<Storyboard x:Key="Touch">
            						<DoubleAnimation Duration="0:0:0.1"
            							Storyboard.TargetName="Thumb"
            							Storyboard.TargetProperty="Width" 
            							To="38"/>
            						<DoubleAnimation Duration="0:0:0.1"
            							Storyboard.TargetName="Thumb"
            							Storyboard.TargetProperty="Height" 
            							To="16"/>
            						<ThicknessAnimation Duration="0:0:0.1"
            							Storyboard.TargetName="Thumb"
            							Storyboard.TargetProperty="Margin"
            							To="-16,7,-16,0" />
            					</Storyboard>
            					<Storyboard x:Key="Release">
            						<DoubleAnimation Duration="0:0:0.15"
            							Storyboard.TargetName="Thumb" 
            							Storyboard.TargetProperty="Width"
            							To="6"/>
            						<DoubleAnimation Duration="0:0:0.1"
            							Storyboard.TargetName="Thumb"
            							Storyboard.TargetProperty="Height" 
            							To="14"/>
            						<ThicknessAnimation Duration="0:0:0.15"
            							Storyboard.TargetName="Thumb"
            							Storyboard.TargetProperty="Margin" 
            							To="0,8,0,0" />
            					</Storyboard>
            				</ControlTemplate.Resources>
            				<Grid x:Name="Grid" >
            					<Rectangle x:Name="HitArea"                           
            						HorizontalAlignment="Stretch"
            						VerticalAlignment="Stretch"
            						Width="38" 
            						Height="38" 
            						Margin="-18,0,-18,0"						   
            						Fill="{StaticResource ControlHitAreaBrush}" />
            					<Rectangle x:Name="Thumb"
            						Margin="0,8,0,0"
            						Width="6"
            						Height="14"
            						HorizontalAlignment="Center"
            						VerticalAlignment="Top"
            						Fill="{DynamicResource {x:Static Custom:SurfaceColors.ThumbEnabledBrushKey}}"/>
            				</Grid>
            				<ControlTemplate.Triggers>
            					<Trigger Property="Custom:TouchExtensions.AreAnyInputDevicesCapturedWithin"
            						Value="True">
            						<Trigger.EnterActions>
            							<BeginStoryboard Storyboard="{StaticResource Touch}" />
            						</Trigger.EnterActions>
            						<Trigger.ExitActions>
            							<BeginStoryboard Storyboard="{StaticResource Release}" />
            						</Trigger.ExitActions>
            					</Trigger>
            					<Trigger Property="IsEnabled"
            						Value="False">
            						<Setter TargetName="Thumb"
            							Value="{DynamicResource {x:Static Custom:SurfaceColors.ThumbDisabledBrushKey}}"
            							Property="Fill"/>
            					</Trigger>
            				</ControlTemplate.Triggers>
            			</ControlTemplate>
            		</Setter.Value>
            	</Setter>
            </Style>
            <Style x:Key="SurfaceSliderHorzThumbStyle"
            	TargetType="{x:Type Custom:SurfaceThumb}"
            	BasedOn="{StaticResource SurfaceThumbStyle}">
            	<Setter Property="MaxHeight" Value="38"/>
            </Style>
            <Style x:Key="SliderVertDecreaseRepeatButtonStyle"
            	TargetType="{x:Type Custom:SurfaceRepeatButton}" 
            	BasedOn="{StaticResource SurfaceHitAreaBaseStyle}">
            	<Setter Property="Interval"
            		Value="150"/>
            	<Setter Property="OverridesDefaultStyle" 
            		Value="True"/>
            	<Setter Property="IsTabStop" 
            		Value="False"/>
            	<Setter Property="Focusable" 
            		Value="False"/>
            	<Setter Property="Template">
            		<Setter.Value>
            			<ControlTemplate TargetType="{x:Type Custom:SurfaceRepeatButton}">
            				<Grid Background="{StaticResource ControlHitAreaBrush}" MinWidth="38" MaxWidth="38">
            					<Rectangle HorizontalAlignment="Left"
            						Margin="12,1,0,1"
            						MinWidth="2"
            						Fill="{DynamicResource BlueHighlight}" Opacity="0.6"/>
            				</Grid>
            			</ControlTemplate>
            		</Setter.Value>
            	</Setter>
            </Style>
            <Style x:Key="SliderVertIncreaseRepeatButtonStyle"
            	TargetType="{x:Type Custom:SurfaceRepeatButton}" 
            	BasedOn="{StaticResource SurfaceHitAreaBaseStyle}">
            	<Setter Property="Interval"		
            		Value="150"/>
            	<Setter Property="OverridesDefaultStyle" 
            		Value="True"/>
            	<Setter Property="IsTabStop" 
            		Value="False"/>
            	<Setter Property="Focusable" 
            		Value="False"/>
            	<Setter Property="Template">
            		<Setter.Value>
            			<ControlTemplate TargetType="{x:Type Custom:SurfaceRepeatButton}">
            				<Grid Background="{StaticResource ControlHitAreaBrush}" MinWidth="38" MaxWidth="38">
            					<Rectangle HorizontalAlignment="Left"
            						Margin="12,1,0,1"
            						MinWidth="2"
            						Fill="{DynamicResource {x:Static Custom:SurfaceColors.SliderTrackIncreaseBackgroundBrushKey}}"/>
            				</Grid>
            			</ControlTemplate>
            		</Setter.Value>
            	</Setter>
            </Style>
            <Style x:Key="SurfaceSliderVertThumbStyle"
            	TargetType="{x:Type Custom:SurfaceThumb}"
            	BasedOn="{StaticResource SurfaceHitAreaBaseStyle}">
            	<Setter Property="OverridesDefaultStyle" Value="true"/>
            	<Setter Property="Custom:TouchVisualizer.Adapter">
            		<Setter.Value>
            			<Custom:RectangleTouchVisualizerAdapter   RadiusX="15"
            				RadiusY="15"/>
            		</Setter.Value>
            	</Setter>
            	<Setter Property="MinHeight" Value="6"/>
            	<Setter Property="MinWidth" Value="6"/>
            	<Setter Property="MaxWidth" Value="38"/>
            	<Setter Property="Template">
            		<Setter.Value>
            			<ControlTemplate TargetType="{x:Type Custom:SurfaceThumb}">
            				<ControlTemplate.Resources>
            					<Storyboard x:Key="Touch">
            						<DoubleAnimation Duration="0:0:0.1"
            							Storyboard.TargetName="Thumb"
            							Storyboard.TargetProperty="Width" 
            							To="16"/>
            						<DoubleAnimation Duration="0:0:0.1"
            							Storyboard.TargetName="Thumb"
            							Storyboard.TargetProperty="Height" 
            							To="38"/>
            						<ThicknessAnimation Duration="0:0:0.1"
            							Storyboard.TargetName="Thumb"
            							Storyboard.TargetProperty="Margin"
            							To="-1,-19,-1,-19" />
            					</Storyboard>
            					<Storyboard x:Key="Release">
            						<DoubleAnimation Duration="0:0:0.15"
            							Storyboard.TargetName="Thumb"
            							To="14"
            							Storyboard.TargetProperty="Width"/>
            						<DoubleAnimation Duration="0:0:0.15"
            							Storyboard.TargetName="Thumb"
            							Storyboard.TargetProperty="Height"
            							To="6"/>
            						<ThicknessAnimation Duration="0:0:0.15"
            							Storyboard.TargetName="Thumb"
            							Storyboard.TargetProperty="Margin"
            							To="0,0,0,0" />
            					</Storyboard>
            				</ControlTemplate.Resources>
            				<Grid x:Name="Grid">
            					<Rectangle	x:Name="HitArea"                       
            						HorizontalAlignment="Stretch"
            						VerticalAlignment="Center"
            						Width="38" 
            						Height="38" 
            						Margin="0,-19,0,-19"
            						Fill="{StaticResource ControlHitAreaBrush}" />
            					<Rectangle 	x:Name="Thumb"
            						Width="14"
            						Height="6"
            						HorizontalAlignment="Stretch"
            						VerticalAlignment="Center"
            						Fill="{DynamicResource BlueHighlight}"/>
            				</Grid>
            				<ControlTemplate.Triggers>
            					<Trigger Property="IsEnabled"
            						Value="False">
            						<Setter TargetName="Thumb"
            							Value="{DynamicResource {x:Static Custom:SurfaceColors.ThumbDisabledBrushKey}}"
            							Property="Fill"/>
            					</Trigger>
            					<Trigger Property="Custom:TouchExtensions.AreAnyInputDevicesCapturedWithin"
            						Value="True">
            						<Trigger.EnterActions>
            							<BeginStoryboard Storyboard="{StaticResource Touch}" />
            						</Trigger.EnterActions>
            						<Trigger.ExitActions>
            							<BeginStoryboard Storyboard="{StaticResource Release}" />
            						</Trigger.ExitActions>
            					</Trigger>
            				</ControlTemplate.Triggers>
            			</ControlTemplate>
            		</Setter.Value>
            	</Setter>
            </Style>
            <Style TargetType="{x:Type Custom:SurfaceSlider}"
            	BasedOn="{StaticResource SurfaceHitAreaBaseStyle}">
            	<Setter Property="Stylus.IsFlicksEnabled"
            		Value="False"/>
            	<Setter Property="Background"
            		Value="{StaticResource ControlHitAreaBrush}"/>
            	<Setter Property="IsMoveToPointEnabled"
            		Value="False"/>
            	<Setter Property="BorderBrush"
            		Value="{DynamicResource {x:Static Custom:SurfaceColors.SliderForegroundBrushKey}}"/>
            	<Setter Property="Template">
            		<Setter.Value>
            			<ControlTemplate TargetType="{x:Type Custom:SurfaceSlider}">
        <!-- Horizontal Orientation -->
            				<Grid x:Name="GridRoot"
            					Background="{TemplateBinding Background}"
            					VerticalAlignment="Stretch"
            					Height="Auto">
            					<Canvas ClipToBounds="False">
            						<Label x:Name="PART_SurfaceToolTip"
            							Style="{StaticResource SliderToolTipStyle}"/>
            					</Canvas>
            					<Grid Margin="16,0,16,0" VerticalAlignment="Top" Height="28">
            <!-- TickBar shows the ticks for Slider -->
            						<TickBar x:Name="TopTick"
            							Visibility="Collapsed"                    
            							Height="4"
            							Placement="Top"
            							Fill="{TemplateBinding BorderBrush}"                     
            							ReservedSpace="0"                             
            							VerticalAlignment="Top"
            							IsDirectionReversed="False"/>
            						<TickBar x:Name="BottomTick"
            							Visibility="Collapsed"                    
            							Height="4" 
            							Placement="Bottom"
            							Fill="{TemplateBinding BorderBrush}"
            							ReservedSpace="0"                             
            							VerticalAlignment="Bottom"
            							IsDirectionReversed="False"/>
            						<Canvas VerticalAlignment="Center" Margin="-1,-8,0,0">
            							<Rectangle x:Name="PART_SelectionRange" 
            								Fill="{DynamicResource {x:Static Custom:SurfaceColors.SliderRangeBrushKey}}"                                    
            								Height="8"
            								Visibility="Hidden"/>
            						</Canvas>
            <!-- The Track lays out the repeat buttons and thumb -->
            						<Track  x:Name="PART_Track" VerticalAlignment="Center" Margin="0,-1,0,0">
            							<Track.DecreaseRepeatButton>
            								<Custom:SurfaceRepeatButton x:Name="SliderDecrease"
            									Margin="-1,0,-1,0"	
            									Background="{TemplateBinding Background}"
            									SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"
            									Style="{StaticResource SliderHorzDecreaseRepeatButtonStyle}"
            									Command="Slider.DecreaseLarge"/>
            							</Track.DecreaseRepeatButton>
            							<Track.IncreaseRepeatButton>
            								<Custom:SurfaceRepeatButton x:Name="SliderIncrease" 
            									Margin="-1,0,-1,0"
            									Background="{TemplateBinding Background}"
            									SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"
            									Style="{StaticResource SliderHorzIncreaseRepeatButtonStyle}"
            									Command="Slider.IncreaseLarge"/>
            							</Track.IncreaseRepeatButton>
            							<Track.Thumb>
            								<Custom:SurfaceThumb  Style="{StaticResource SurfaceSliderHorzThumbStyle}"
            									Background="{TemplateBinding Background}"
            									SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"
            									x:Name="Thumb" />
            							</Track.Thumb>
            						</Track>
            					</Grid>
            				</Grid>
            				<ControlTemplate.Triggers>
            					<Trigger Property="IsSelectionRangeEnabled" 
            						Value="True">
            						<Setter Property="Visibility" 
            							TargetName="PART_SelectionRange" 
            							Value="Visible"/>
            					</Trigger>
            					<Trigger Property="TickPlacement"
            						Value="TopLeft">
            						<Setter Property="Visibility"
            							Value="Visible"
            							TargetName="TopTick"/>
            					</Trigger>
            					<Trigger Property="TickPlacement"
            						Value="BottomRight">
            						<Setter Property="Visibility"
            							Value="Visible"
            							TargetName="BottomTick"/>
            					</Trigger>
            					<Trigger Property="TickPlacement"
            						Value="Both">
            						<Setter Property="Visibility"
            							Value="Visible"
            							TargetName="TopTick"/>
            						<Setter Property="Visibility"
            							Value="Visible"
            							TargetName="BottomTick"/>
            					</Trigger>
            					<Trigger Property="IsEnabled"
            						Value="False">
            						<Setter Property="Opacity"  
            							TargetName="SliderDecrease"                              
            							Value="0.25"/>
            						<Setter Property="Opacity"  
            							TargetName="SliderIncrease"                              
            							Value="0.5"/>
            						<Setter Property="Opacity"  
            							TargetName="TopTick"                              
            							Value="0.25"/>
            						<Setter Property="Opacity"  
            							TargetName="BottomTick"                              
            							Value="0.25"/>
            					</Trigger>
            				</ControlTemplate.Triggers>
            			</ControlTemplate>
            		</Setter.Value>
            	</Setter>

            	<Style.Triggers>
    <!-- Vertical orientation -->
            		<Trigger Property="Orientation"
            			Value="Vertical">
            			<Setter Property="Template">
            				<!--Change the whole template-->
            				<Setter.Value>
            					<ControlTemplate TargetType="{x:Type Custom:SurfaceSlider}">
            						<Grid x:Name="GridRoot"
            							Background="{TemplateBinding Background}"
            							HorizontalAlignment="Stretch"
            							Width="Auto">
            							<Grid Margin="0,16,0,16" HorizontalAlignment="Left" Width="28">
            								<TickBar x:Name="TopTick"
            									Visibility="Collapsed"
            									Width="4"
            									Placement="Left"
            									Fill="{TemplateBinding BorderBrush}"
            									ReservedSpace="0"
            									HorizontalAlignment="Left"
            									IsDirectionReversed="False"/>
            								<TickBar x:Name="BottomTick"
            									Visibility="Collapsed"
            									Width="4"
            									Placement="Right"
            									Fill="{TemplateBinding BorderBrush}"
            									ReservedSpace="0"
            									HorizontalAlignment="Right"
            									IsDirectionReversed="False"/>
            								<Canvas HorizontalAlignment="Center" Margin="-8,1,0,0">
            									<Rectangle x:Name="PART_SelectionRange"
            										Fill="{DynamicResource {x:Static Custom:SurfaceColors.SliderTrackIncreaseBackgroundBrushKey}}"                                                
            										Width="8"
            										Visibility="Hidden"/>
            								</Canvas>
                <!-- The Track lays out the repeat buttons and thumb -->
            								<Track  x:Name="PART_Track" HorizontalAlignment="Center">
            									<Track.DecreaseRepeatButton>
            										<Custom:SurfaceRepeatButton x:Name="SliderDecrease"
            											Margin="0,-1,0,-1"	
            											Background="{TemplateBinding Background}"
            											SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"
            											Style="{StaticResource SliderVertDecreaseRepeatButtonStyle}"
            											Command="Slider.DecreaseLarge"/>
            									</Track.DecreaseRepeatButton>
            									<Track.IncreaseRepeatButton>
            										<Custom:SurfaceRepeatButton x:Name="SliderIncrease"
            											Margin="0,-1,0,-1"	
            											Background="{TemplateBinding Background}"
            											SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"
            											Style="{StaticResource SliderVertIncreaseRepeatButtonStyle}"
            											Command="Slider.IncreaseLarge"/>
            									</Track.IncreaseRepeatButton>
            									<Track.Thumb>
            										<Custom:SurfaceThumb  Style="{StaticResource SurfaceSliderVertThumbStyle}"
            											Background="{TemplateBinding Background}"
            											SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"
            											x:Name="Thumb" />
            									</Track.Thumb>
            								</Track>
            							</Grid>
            							<Canvas ClipToBounds="False">
            								<Label  x:Name="PART_SurfaceToolTip"
            									Style="{StaticResource SliderToolTipStyle}"/>
            							</Canvas>
            						</Grid>
            						<ControlTemplate.Triggers>
            							<Trigger Property="IsSelectionRangeEnabled" 
            								Value="True">
            								<Setter Property="Visibility" 
            									TargetName="PART_SelectionRange" 
            									Value="Visible"/>
            							</Trigger>
            							<Trigger Property="TickPlacement"
            								Value="TopLeft">
            								<Setter Property="Visibility"
            									Value="Visible"
            									TargetName="TopTick"/>
            							</Trigger>
            							<Trigger Property="TickPlacement"
            								Value="BottomRight">
            								<Setter Property="Visibility"
            									Value="Visible"
            									TargetName="BottomTick"/>
            							</Trigger>
            							<Trigger Property="TickPlacement"
            								Value="Both">
            								<Setter Property="Visibility"
            									Value="Visible"
            									TargetName="TopTick"/>
            								<Setter Property="Visibility"
            									Value="Visible"
            									TargetName="BottomTick"/>
            							</Trigger>
            							<Trigger Property="IsEnabled"
            								Value="False">
            								<Setter Property="Opacity"  
            									TargetName="SliderDecrease"                              
            									Value="0.25"/>
            								<Setter Property="Opacity"  
            									TargetName="SliderIncrease"                              
            									Value="0.5"/>
            								<Setter Property="Opacity"  
            									TargetName="TopTick"                              
            									Value="0.25"/>
            								<Setter Property="Opacity"  
            									TargetName="BottomTick"                              
            									Value="0.25"/>
            							</Trigger>
            						</ControlTemplate.Triggers>
            					</ControlTemplate>
            				</Setter.Value>
            			</Setter>
            		</Trigger>
            	</Style.Triggers>
            </Style>

        
        </ResourceDictionary>
    </Application.Resources>
</Application>
